# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=metoscan
pkgver=05
pkgrel=4
groups=('blackarch' 'blackarch-webapp')
pkgdesc='Tool for scanning the HTTP methods supported by a webserver.'
url='http://www.open-labs.org/'
license=('custom')
depends=('curl')
makedepends=('gcc' 'make')
arch=('x86_64' 'aarch64')
#source=("http://www.open-labs.org/${pkgname}${pkgver}.tar.gz")
source=("https://web.archive.org/web/20110902174832/http://open-labs.org/$pkgname$pkgver.tar.gz")
sha512sums=('734403caf956b73e2e09a01e058a7deb8636b93f557f7af28ff317d62a49636d4c3d1aef778673ba1709c6708114e088fd546fed87129a5a347554ab3a1ceae2')

prepare() {
  cd "${pkgname}${pkgver}"

  sed -i '/CURLOPT_MUTE/d' get_url.c
  sed -i "s:gcc :gcc $CFLAGS :" Makefile
}

build() {
  cd "${pkgname}${pkgver}"

  make
}

package() {
  cd "${pkgname}${pkgver}"

  install -Dm 755 $pkgname "$pkgdir/usr/bin/$pkgname"
  install -Dm 644 -t "$pkgdir/usr/share/doc/$pkgname/" README.txt
}

